Package | hl7.fhir.uv.xver |
Type | StructureMap |
Id | Id |
FHIR Version | R5 |
Source | http://hl7.org/fhir/extensions/https://build.fhir.org/ig/HL7/fhir-cross-version/StructureMap-MedicationStatement2to3.html |
Url | http://hl7.org/fhir/StructureMap/MedicationStatement2to3 |
Version | 0.1.0 |
Status | active |
Date | 2024-02-22T03:16:50+00:00 |
Name | MedicationStatement2to3 |
Title | MedicationStatement Transforms: R2 to R3 |
Experimental | False |
Realm | uv |
Authority | hl7 |
Description | MedicationStatementTransformsR2toR3 |
No resources found
No resources found
Note: links and images are rebased to the (stated) source
/// url = 'http://hl7.org/fhir/StructureMap/MedicationStatement2to3' /// name = 'MedicationStatement2to3' /// title = 'MedicationStatement Transforms: R2 to R3' /// status = 'active' uses "http://hl7.org/fhir/1.0/MedicationStatement" alias MedicationStatementR2 as source uses "http://hl7.org/fhir/3.0/MedicationStatement" alias MedicationStatement as target imports "http://hl7.org/fhir/StructureMap/*2to3" group MedicationStatement(source src : MedicationStatementR2, target tgt : MedicationStatement) extends DomainResource <<type+>> { src.identifier -> tgt.identifier "MedicationStatement-identifier"; src.patient -> tgt.subject "MedicationStatement-subject"; src.informationSource -> tgt.informationSource "MedicationStatement-informationSource"; src.dateAsserted -> tgt.dateAsserted "MedicationStatement-dateAsserted"; src.status -> tgt.status "MedicationStatement-status"; src.wasNotTaken as vt where $this = true -> tgt.taken = 'n' "MedicationStatement-wasNotTaken"; src.wasNotTaken as vt where $this = false -> tgt.taken = 'y' "MedicationStatement-wasNotTaken"; src.reasonNotTaken -> tgt.reasonNotTaken "MedicationStatement-reasonNotTaken"; src.reasonForUse where $this is CodeableConcept -> tgt.reasonCode "MedicationStatement-reasonForUse"; src.reasonForUse where $this is Reference -> tgt.reasonReference "MedicationStatement-reasonForUse"; src.effective -> tgt.effective "MedicationStatement-effective"; src.note -> tgt.note "MedicationStatement-note"; src.supportingInformation -> tgt.derivedFrom "MedicationStatement-supportingInformation"; src.medication -> tgt.medication "MedicationStatement-medication"; src.dosage as vs0 -> tgt.dosage as vt0 then mstDosage(vs0, vt0) "MedicationStatement-dosage"; } group mstDosage(source src, target tgt) extends Element { src.text -> tgt.text "DosageInstruction-text"; src.timing -> tgt.timing "DosageInstruction-timing"; src.asNeeded -> tgt.asNeeded "DosageInstruction-asNeeded"; src.site where $this is CodeableConcept -> tgt.site "DosageInstruction-site"; src.route -> tgt.route "DosageInstruction-route"; src.method -> tgt.method "DosageInstruction-method"; src.quantity -> tgt.dose "DosageInstruction-quantity"; src.rate -> tgt.rate "DosageInstruction-rate"; src.maxDosePerPeriod -> tgt.maxDosePerPeriod "DosageInstruction-maxDosePerPeriod"; }
{
"resourceType" : "StructureMap",
"id" : "MedicationStatement2to3",
"text" : {
"status" : "generated",
"div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><pre class=\"fml\">\r\n<span style=\"color: #cc00cc\">/// <b>url</b> = </span><span style=\"color: blue\">'http://hl7.org/fhir/StructureMap/MedicationStatement2to3'</span>\r\n<span style=\"color: #cc00cc\">/// <b>name</b> = </span><span style=\"color: blue\">'MedicationStatement2to3'</span>\r\n<span style=\"color: #cc00cc\">/// <b>title</b> = </span><span style=\"color: blue\">'MedicationStatement Transforms: R2 to R3'</span>\r\n<span style=\"color: #cc00cc\">/// <b>status</b> = </span><span style=\"color: blue\">'active'</span>\r\n\r\n<b>uses</b><span style=\"color: navy\"> "</span>http://hl7.org/fhir/1.0/MedicationStatement<span style=\"color: navy\">" </span><b>alias </b>MedicationStatementR2 <b>as </b><b>source</b>\r\n<b>uses</b><span style=\"color: navy\"> "</span>http://hl7.org/fhir/3.0/MedicationStatement<span style=\"color: navy\">" </span><b>alias </b>MedicationStatement <b>as </b><b>target</b>\r\n\r\n<b>imports</b><span style=\"color: navy\"> "</span>http://hl7.org/fhir/StructureMap/*2to3<span style=\"color: navy\">"\r\n</span>\r\n<b>group </b>MedicationStatement<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span><span style=\"color: navy\"> : </span>MedicationStatementR2, <b>target</b> <span style=\"color: maroon\">tgt</span><span style=\"color: navy\"> : </span>MedicationStatement<span style=\"color: navy\">)</span><b> extends </b>DomainResource<b> <<type+>></b><span style=\"color: navy\"> {\r\n</span> src.identifier<span style=\"color: navy\"><b> -> </b></span>tgt.identifier <i>"MedicationStatement-identifier"</i><span style=\"color: navy\">;</span>\r\n src.patient<span style=\"color: navy\"><b> -> </b></span>tgt.subject <i>"MedicationStatement-subject"</i><span style=\"color: navy\">;</span>\r\n src.informationSource<span style=\"color: navy\"><b> -> </b></span>tgt.informationSource <i>"MedicationStatement-informationSource"</i><span style=\"color: navy\">;</span>\r\n src.dateAsserted<span style=\"color: navy\"><b> -> </b></span>tgt.dateAsserted <i>"MedicationStatement-dateAsserted"</i><span style=\"color: navy\">;</span>\r\n src.status<span style=\"color: navy\"><b> -> </b></span>tgt.status <i>"MedicationStatement-status"</i><span style=\"color: navy\">;</span>\r\n src.wasNotTaken<b> as </b><span style=\"color: maroon\">vt</span><b> where </b>$this = true<span style=\"color: navy\"><b> -> </b></span>tgt.taken = <span style=\"color: blue\">'n'</span> <i>"MedicationStatement-wasNotTaken"</i><span style=\"color: navy\">;</span>\r\n src.wasNotTaken<b> as </b><span style=\"color: maroon\">vt</span><b> where </b>$this = false<span style=\"color: navy\"><b> -> </b></span>tgt.taken = <span style=\"color: blue\">'y'</span> <i>"MedicationStatement-wasNotTaken"</i><span style=\"color: navy\">;</span>\r\n src.reasonNotTaken<span style=\"color: navy\"><b> -> </b></span>tgt.reasonNotTaken <i>"MedicationStatement-reasonNotTaken"</i><span style=\"color: navy\">;</span>\r\n src.reasonForUse<b> where </b>$this is CodeableConcept<span style=\"color: navy\"><b> -> </b></span>tgt.reasonCode <i>"MedicationStatement-reasonForUse"</i><span style=\"color: navy\">;</span>\r\n src.reasonForUse<b> where </b>$this is Reference<span style=\"color: navy\"><b> -> </b></span>tgt.reasonReference <i>"MedicationStatement-reasonForUse"</i><span style=\"color: navy\">;</span>\r\n src.effective<span style=\"color: navy\"><b> -> </b></span>tgt.effective <i>"MedicationStatement-effective"</i><span style=\"color: navy\">;</span>\r\n src.note<span style=\"color: navy\"><b> -> </b></span>tgt.note <i>"MedicationStatement-note"</i><span style=\"color: navy\">;</span>\r\n src.supportingInformation<span style=\"color: navy\"><b> -> </b></span>tgt.derivedFrom <i>"MedicationStatement-supportingInformation"</i><span style=\"color: navy\">;</span>\r\n src.medication<span style=\"color: navy\"><b> -> </b></span>tgt.medication <i>"MedicationStatement-medication"</i><span style=\"color: navy\">;</span>\r\n src.dosage<b> as </b><span style=\"color: maroon\">vs0</span><span style=\"color: navy\"><b> -> </b></span>tgt.dosage<b> as </b><span style=\"color: maroon\">vt0</span><b> then </b>mstDosage<span style=\"color: navy\">(</span><span style=\"color: maroon\">vs0</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">vt0</span><span style=\"color: navy\">)</span> <i>"MedicationStatement-dosage"</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span><b>group </b>mstDosage<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">src</span>, <b>target</b> <span style=\"color: maroon\">tgt</span><span style=\"color: navy\">)</span><b> extends </b>Element<span style=\"color: navy\"> {\r\n</span> src.text<span style=\"color: navy\"><b> -> </b></span>tgt.text <i>"DosageInstruction-text"</i><span style=\"color: navy\">;</span>\r\n src.timing<span style=\"color: navy\"><b> -> </b></span>tgt.timing <i>"DosageInstruction-timing"</i><span style=\"color: navy\">;</span>\r\n src.asNeeded<span style=\"color: navy\"><b> -> </b></span>tgt.asNeeded <i>"DosageInstruction-asNeeded"</i><span style=\"color: navy\">;</span>\r\n src.site<b> where </b>$this is CodeableConcept<span style=\"color: navy\"><b> -> </b></span>tgt.site <i>"DosageInstruction-site"</i><span style=\"color: navy\">;</span>\r\n src.route<span style=\"color: navy\"><b> -> </b></span>tgt.route <i>"DosageInstruction-route"</i><span style=\"color: navy\">;</span>\r\n src.method<span style=\"color: navy\"><b> -> </b></span>tgt.method <i>"DosageInstruction-method"</i><span style=\"color: navy\">;</span>\r\n src.quantity<span style=\"color: navy\"><b> -> </b></span>tgt.dose <i>"DosageInstruction-quantity"</i><span style=\"color: navy\">;</span>\r\n src.rate<span style=\"color: navy\"><b> -> </b></span>tgt.rate <i>"DosageInstruction-rate"</i><span style=\"color: navy\">;</span>\r\n src.maxDosePerPeriod<span style=\"color: navy\"><b> -> </b></span>tgt.maxDosePerPeriod <i>"DosageInstruction-maxDosePerPeriod"</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span></pre></div>"
},
"extension" : [
{
"url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
"valueCode" : "fhir"
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm",
"valueInteger" : 1,
"_valueInteger" : {
"extension" : [
{
"url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-conformance-derivedFrom",
"valueCanonical" : "http://hl7.org/fhir/extensions/ImplementationGuide/hl7.fhir.uv.xver"
}
]
}
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
"valueCode" : "draft",
"_valueCode" : {
"extension" : [
{
"url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-conformance-derivedFrom",
"valueCanonical" : "http://hl7.org/fhir/extensions/ImplementationGuide/hl7.fhir.uv.xver"
}
]
}
}
],
"url" : "http://hl7.org/fhir/StructureMap/MedicationStatement2to3",
"version" : "0.1.0",
"name" : "MedicationStatement2to3",
"title" : "MedicationStatement Transforms: R2 to R3",
"status" : "active",
"date" : "2024-02-22T03:16:50+00:00",
"publisher" : "HL7 International / FHIR Infrastructure",
"contact" : [
{
"telecom" : [
{
"system" : "url",
"value" : "http://www.hl7.org/Special/committees/fiwg"
}
]
}
],
"description" : "MedicationStatementTransformsR2toR3",
"jurisdiction" : [
{
"coding" : [
{
"system" : "http://unstats.un.org/unsd/methods/m49/m49.htm",
"code" : "001"
}
]
}
],
"structure" : [
{
"url" : "http://hl7.org/fhir/1.0/MedicationStatement",
"mode" : "source",
"alias" : "MedicationStatementR2"
},
{
"url" : "http://hl7.org/fhir/3.0/MedicationStatement",
"mode" : "target",
"alias" : "MedicationStatement"
}
],
"import" : [
"http://hl7.org/fhir/StructureMap/*2to3"
],
"group" : [
{
"name" : "MedicationStatement",
"extends" : "DomainResource",
"typeMode" : "type-and-types",
"input" : [
{
"name" : "src",
"type" : "MedicationStatementR2",
"mode" : "source"
},
{
"name" : "tgt",
"type" : "MedicationStatement",
"mode" : "target"
}
],
"rule" : [
{
"name" : "MedicationStatement-identifier",
"source" : [
{
"context" : "src",
"element" : "identifier",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "identifier",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-subject",
"source" : [
{
"context" : "src",
"element" : "patient",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "subject",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-informationSource",
"source" : [
{
"context" : "src",
"element" : "informationSource",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "informationSource",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-dateAsserted",
"source" : [
{
"context" : "src",
"element" : "dateAsserted",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "dateAsserted",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-status",
"source" : [
{
"context" : "src",
"element" : "status",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "status",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-wasNotTaken",
"source" : [
{
"context" : "src",
"element" : "wasNotTaken",
"variable" : "vt",
"condition" : "$this = true"
}
],
"target" : [
{
"context" : "tgt",
"element" : "taken",
"transform" : "copy",
"parameter" : [
{
"valueString" : "n"
}
]
}
]
},
{
"name" : "MedicationStatement-wasNotTaken",
"source" : [
{
"context" : "src",
"element" : "wasNotTaken",
"variable" : "vt",
"condition" : "$this = false"
}
],
"target" : [
{
"context" : "tgt",
"element" : "taken",
"transform" : "copy",
"parameter" : [
{
"valueString" : "y"
}
]
}
]
},
{
"name" : "MedicationStatement-reasonNotTaken",
"source" : [
{
"context" : "src",
"element" : "reasonNotTaken",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "reasonNotTaken",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-reasonForUse",
"source" : [
{
"context" : "src",
"element" : "reasonForUse",
"variable" : "vvv",
"condition" : "$this is CodeableConcept"
}
],
"target" : [
{
"context" : "tgt",
"element" : "reasonCode",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-reasonForUse",
"source" : [
{
"context" : "src",
"element" : "reasonForUse",
"variable" : "vvv",
"condition" : "$this is Reference"
}
],
"target" : [
{
"context" : "tgt",
"element" : "reasonReference",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-effective",
"source" : [
{
"context" : "src",
"element" : "effective",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "effective",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-note",
"source" : [
{
"context" : "src",
"element" : "note",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "note",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-supportingInformation",
"source" : [
{
"context" : "src",
"element" : "supportingInformation",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "derivedFrom",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-medication",
"source" : [
{
"context" : "src",
"element" : "medication",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "medication",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "MedicationStatement-dosage",
"source" : [
{
"context" : "src",
"element" : "dosage",
"variable" : "vs0"
}
],
"target" : [
{
"context" : "tgt",
"element" : "dosage",
"variable" : "vt0"
}
],
"dependent" : [
{
"name" : "mstDosage",
"parameter" : [
{
"valueId" : "vs0"
},
{
"valueId" : "vt0"
}
]
}
]
}
]
},
{
"name" : "mstDosage",
"extends" : "Element",
"input" : [
{
"name" : "src",
"mode" : "source"
},
{
"name" : "tgt",
"mode" : "target"
}
],
"rule" : [
{
"name" : "DosageInstruction-text",
"source" : [
{
"context" : "src",
"element" : "text",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "text",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "DosageInstruction-timing",
"source" : [
{
"context" : "src",
"element" : "timing",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "timing",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "DosageInstruction-asNeeded",
"source" : [
{
"context" : "src",
"element" : "asNeeded",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "asNeeded",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "DosageInstruction-site",
"source" : [
{
"context" : "src",
"element" : "site",
"variable" : "vvv",
"condition" : "$this is CodeableConcept"
}
],
"target" : [
{
"context" : "tgt",
"element" : "site",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "DosageInstruction-route",
"source" : [
{
"context" : "src",
"element" : "route",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "route",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "DosageInstruction-method",
"source" : [
{
"context" : "src",
"element" : "method",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "method",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "DosageInstruction-quantity",
"source" : [
{
"context" : "src",
"element" : "quantity",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "dose",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "DosageInstruction-rate",
"source" : [
{
"context" : "src",
"element" : "rate",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "rate",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
},
{
"name" : "DosageInstruction-maxDosePerPeriod",
"source" : [
{
"context" : "src",
"element" : "maxDosePerPeriod",
"variable" : "vvv"
}
],
"target" : [
{
"context" : "tgt",
"element" : "maxDosePerPeriod",
"variable" : "vvv",
"transform" : "create"
}
],
"dependent" : [
{
"name" : "DefaultMappingGroupAnonymousAlias",
"parameter" : [
{
"valueId" : "vvv"
},
{
"valueId" : "vvv"
}
]
}
]
}
]
}
]
}
XIG built as of ??metadata-date??. Found ??metadata-resources?? resources in ??metadata-packages?? packages.